package myoa

class ProEmployee {
    String comment
    static belongsTo = [proCompany: ProCompany, employee: Employee]
    static constraints = {
        comment(blank: true)

        /**
         * GSP页面保证了proCompany.companyId等于employee.companyId
         * <g:select name="employee.id" from="${proCompany.company.employees}"/>
         */
        employee(unique: 'proCompany')
    }
}
